package c.c.a;

import android.content.SharedPreferences;
import org.json.JSONObject;

public class m extends b2 {
    public final g2 e;

    public m(g2 g2Var) {
        super(true, false, false);
        this.e = g2Var;
    }

    public boolean b(JSONObject jSONObject) {
        SharedPreferences sharedPreferences = this.e.e;
        String str = "install_id";
        String string = sharedPreferences.getString(str, null);
        String str2 = "device_id";
        String string2 = sharedPreferences.getString(str2, null);
        String str3 = "ssid";
        String string3 = sharedPreferences.getString(str3, null);
        c.b(jSONObject, str, string);
        c.b(jSONObject, str2, string2);
        c.b(jSONObject, str3, string3);
        str = "register_time";
        long j = 0;
        long j2 = sharedPreferences.getLong(str, 0);
        if ((c.i(string) && c.i(string2)) || j2 == 0) {
            j = j2;
        } else {
            sharedPreferences.edit().putLong(str, 0).apply();
        }
        jSONObject.put(str, j);
        return true;
    }
}
